package com.bluegalaxy.nhb.snservice.dao;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.jdbc.core.JdbcTemplate;
import org.springframework.stereotype.Repository;

import java.util.List;
import java.util.Map;

@Repository
public class SynDao {

    @Autowired
//    @Qualifier("anJdbcTemplate")
    private JdbcTemplate anJdbcTemplate;

//    public SynDao(JdbcTemplate jdbcTemplate) {
//        this.jdbcTemplate = jdbcTemplate;
//    }

    public List<Map<String,Object>> selectUsers(Map<String,Object> param){
        String sql = "select * from users";
        List<Map<String, Object>> list = anJdbcTemplate.queryForList(sql);
        return list;
    }

}
